home *** CD-ROM | disk | FTP | other *** search
/ SuperHack / SuperHack CD.bin / CODING / DEMOS / CHECKSRC.ZIP / CHECKER.PAS < prev    next >
Encoding:
Pascal/Delphi Source File  |  1994-10-11  |  15.1 KB  |  493 lines

  1. { Here it is, the source of CHECKER!! WOW?!?!?!?!?....
  2.   For some wierd reason certain persons wanted to see this....
  3.   Well, they must be feeling pretty happy know:]
  4.   But O.K. I rewrote the source a bit to make it a little more 'readable'
  5.   and understandable.... I don't have the time nor want to include to many
  6.   comments. But it ain't to dificult to understand so don't dispare.....
  7.                                                   -SHARP-
  8. }
  9.  
  10. {$M 4000,0,65000 }
  11. uses crt,ucihsc,vga;
  12.  
  13. type
  14.      vlak       = array[1..675] of byte;
  15.  
  16. var  i,j,c      : integer;
  17.      cols       : vlak;
  18.      pal        : array[0..256,1..3] of byte;
  19.      Text       : string[255];
  20.      Textpos    : integer;
  21.      TextX      : integer;
  22.      TextAddr   : integer;
  23.      subX       : integer;
  24.  
  25.      count      : integer;
  26.      placecnt   : integer;
  27.  
  28. const
  29. { standard checker }
  30.   check1        : vlak =
  31.   ( 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63,
  32.    0,0,42,0,0,42,0,0,42,0,0,42,0,0,42,0,0,42,0,0,42,0,0,42,
  33.   63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63,
  34.    0,0,45,0,0,45,0,0,45,0,0,45,0,0,45,0,0,45,0,0,45,0,0,45,
  35.   63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63,
  36.    0,0,48,0,0,48,0,0,48,0,0,48,0,0,48,0,0,48,0,0,48,0,0,48,
  37.   63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63,
  38.    0,0,51,0,0,51,0,0,51,0,0,51,0,0,51,0,0,51,0,0,51,0,0,51,
  39.   63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63,
  40.    0,0,54,0,0,54,0,0,54,0,0,54,0,0,54,0,0,54,0,0,54,0,0,54,
  41.   63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63,
  42.    0,0,57,0,0,57,0,0,57,0,0,57,0,0,57,0,0,57,0,0,57,0,0,57,
  43.   63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63,
  44.    0,0,60,0,0,60,0,0,60,0,0,60,0,0,60,0,0,60,0,0,60,0,0,60,
  45.   63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63,
  46.    0,0,63,0,0,63,0,0,63,0,0,63,0,0,63,0,0,63,0,0,63,0,0,63,
  47.  
  48.   0,0,45,0,0,45,0,0,45,0,0,45,0,0,45,0,0,45,0,0,45,63,63,63,
  49.    63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63,
  50.   0,0,48,0,0,48,0,0,48,0,0,48,0,0,48,0,0,48,0,0,48,63,63,63,
  51.    63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63,
  52.   0,0,51,0,0,51,0,0,51,0,0,51,0,0,51,0,0,51,0,0,51,63,63,63,
  53.    63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63,
  54.   0,0,54,0,0,54,0,0,54,0,0,54,0,0,54,0,0,54,0,0,54,63,63,63,
  55.    63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63,
  56.   0,0,57,0,0,57,0,0,57,0,0,57,0,0,57,0,0,57,0,0,57,63,63,63,
  57.    63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63,
  58.   0,0,60,0,0,60,0,0,60,0,0,60,0,0,60,0,0,60,0,0,60,63,63,63,
  59.    63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63,
  60.   0,0,63,0,0,63,0,0,63,0,0,63,0,0,63,0,0,63,0,0,63,63,63,63,
  61.    63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63, 63,63,63);
  62.  
  63. { UN checker : }
  64.    check2              : vlak = (
  65.   34,34,34, 34,34,34, 34,34,34, 34,34,34, 34,34,34, 0,0,40, 0,0,40, 0,0,40, 0,0,40, 34,34,34, 34,34,34, 34,34,34, 34,34,34,
  66.   34,34,34, 34,34,34,
  67.   36,36,36, 36,36,36, 36,36,36, 36,36,36, 0,0,42, 0,0,42, 0,0,42, 0,0,42, 0,0,42, 0,0,42, 36,36,36, 36,36,36, 36,36,36,
  68.   36,36,36, 36,36,36,
  69.   38,38,38, 38,38,38, 38,38,38, 0,0,44, 0,0,44, 40,0,0, 40,0,0, 38,38,38, 38,38,38, 0,0,44, 0,0,44, 38,38,38, 40,0,0,
  70.   40,0,0, 38,38,38,
  71.   40,40,40, 40,40,40, 40,40,40, 0,0,46, 0,0,46, 42,0,0, 40,40,40, 40,40,40, 40,40,40, 0,0,46, 0,0,46, 40,40,40, 40,40,40,
  72.   42,0,0, 42,0,0,
  73.   42,42,42, 42,42,42, 0,0,48, 0,0,48, 44,0,0, 44,0,0, 42,42,42, 42,42,42, 42,42,42, 0,0,48, 0,0,48, 42,42,42, 42,42,42,
  74.   44,0,0, 44,0,0,
  75.   44,44,44, 44,44,44, 0,0,50, 0,0,50, 46,0,0, 46,0,0, 44,44,44, 44,44,44, 44,44,44, 44,44,44, 0,0,50, 0,0,50, 44,44,44,
  76.   46,0,0, 46,0,0,
  77.   46,46,46, 46,46,46, 0,0,52, 0,0,52, 48,0,0, 48,0,0, 46,46,46, 46,46,46, 46,46,46, 46,46,46, 0,0,52, 0,0,52, 46,46,46,
  78.   48,0,0, 48,0,0,
  79.   48,48,48, 0,0,54, 0,0,54, 48,48,48, 50,0,0, 50,0,0, 48,48,48, 48,48,48, 48,48,48, 48,48,48, 0,0,54, 0,0,54, 50,0,0,
  80.   50,0,0, 48,48,48,
  81.   50,50,50, 0,0,56, 0,0,56, 50,50,50, 52,0,0, 52,0,0, 50,50,50, 50,50,50, 50,50,50, 50,50,50, 0,0,56, 0,0,56, 52,0,0,
  82.   52,0,0, 50,50,50,
  83.   52,52,52, 0,0,58, 0,0,58, 52,52,52, 52,52,52, 54,0,0, 54,0,0, 52,52,52, 52,52,52, 52,52,52, 0,0,58, 0,0,58, 54,0,0,
  84.   54,0,0, 52,52,52,
  85.   54,54,54, 0,0,60, 0,0,60, 54,54,54, 54,54,54, 56,0,0, 56,0,0, 54,54,54, 54,54,54, 54,54,54, 0,0,60, 0,0,60, 56,0,0,
  86.   54,54,54, 54,54,54,
  87.   56,56,56, 56,56,56, 0,0,62, 0,0,62, 58,0,0, 58,0,0, 58,0,0, 56,56,56, 56,56,56, 0,0,62, 0,0,62, 58,0,0, 58,0,0,
  88.   56,56,56, 56,56,56,
  89.   58,58,58, 58,58,58, 58,58,58, 58,58,58, 60,0,0, 60,0,0, 60,0,0, 60,0,0, 60,0,0, 60,0,0, 60,0,0, 60,0,0, 58,58,58,
  90.   58,58,58, 58,58,58,
  91.   60,60,60, 60,60,60, 60,60,60, 60,60,60, 62,0,0, 62,0,0, 60,60,60, 62,0,0, 62,0,0, 62,0,0, 62,0,0, 60,60,60, 60,60,60,
  92.   60,60,60, 60,60,60,
  93.   62,62,62, 62,62,62, 62,62,62, 62,62,62, 62,62,62, 62,62,62, 62,62,62, 62,62,62, 62,62,62, 62,62,62, 62,62,62, 62,62,62,
  94.   62,62,62, 62,62,62, 62,62,62);
  95.  
  96. { Font..... }
  97. {$L BIG.OBJ}
  98. {$F+}
  99. procedure BigFont; external;
  100. {$F-}
  101.  
  102. { Change all palette intries.....}
  103. procedure allpal;
  104. label     palcycl;
  105. begin
  106.   port[$3c8] :=0;
  107.   asm
  108.     cli
  109.     push ds
  110.     mov dx,3c9h
  111.     mov cx,226*3
  112.     mov ax,seg(pal)
  113.     mov ds,ax
  114.     mov si,offset pal
  115. palcycl:
  116.     lodsb
  117.     out dx,al
  118.     loop palcycl
  119.     pop ds
  120.     sti
  121.   end;
  122. end;
  123.  
  124. procedure Einde;
  125. var vangaf      : char;
  126. begin
  127.   if keypressed then vangaf:=readkey;
  128.   asm
  129.     mov ax,3h
  130.     int 10h
  131.   end;
  132.   writeln('                                UNICORN UTM 1994 ');
  133.   writeln;
  134.   writeln(' Checkerboard, made by SHARP, hope ya liked it..... ');
  135.   writeln;
  136.   writeln(' UNICORN UTM can be reached in theze wayz:');
  137.   writeln(' Writing to:');
  138.   writeln('   UNICORN UTM ');
  139.   writeln('   Bastiaan Olij ');
  140.   writeln('   Pr. Hendrikstraat 30');
  141.   writeln('   2161 SE LISSE');
  142.   writeln('   NEDERLAND');
  143.   writeln;
  144.   writeln(' Or contact via FIDO: Nr 2:500/143.2280.');
  145.   writeln;
  146.   writeln(' Hace fun!!!...grtz to all....l8r....');
  147.   Stopplaying;
  148.   RemoveHSCfile;
  149.   UndoHSC;
  150.   halt(0);
  151. end;
  152.  
  153. { Change the checker... }
  154. procedure cyclecols(x,y : integer);
  155. var  buff    : vlak;
  156.      b1,b2   : integer;
  157.      nv1,nv2 : integer;
  158.      i1,j1   : integer;
  159. begin
  160.   for j := 0 to 14 do begin
  161.     nv1:=((15+j+x) mod 15) * 3;
  162.     for i:= 0 to 14 do begin
  163.       nv2:=45*((15+i+y) mod 15);
  164.       i1:=45*i;
  165.       j1:=j*3;
  166.       buff[i1 + j1 + 1]:=cols[nv2+nv1+1];
  167.       buff[i1 + j1 + 2]:=cols[nv2+nv1+2];
  168.       buff[i1 + j1 + 3]:=cols[nv2+nv1+3];
  169.     end;
  170.   end;
  171.   cols:=buff;
  172. end;
  173.  
  174. { Draw the checkerboard once so you can keep using it }
  175. procedure makecheck;
  176. var       x,y,x3,z3 : integer;
  177.           xc,yc     : integer;
  178.           col       : byte;
  179. begin
  180.   for y:=110 to 210 do begin
  181.     z3:=10000 div (y-50);
  182.     yc:=z3 mod 15;
  183.     for x:=0 to 319 do begin
  184.       x3:=z3 * (x-160);
  185.       xc:=((x3 div 200) + 32000) mod 15;
  186.       col:=(xc+yc*15)+1;
  187.       PutPixX(X,Y,Col);
  188.     end;
  189.   end;
  190. end;
  191.  
  192. { Update the hardware scoller (yes it is slow and unoptimized but it works
  193.   fine!!!! }
  194. procedure cycletext;
  195. var charnr          : integer;
  196.     shifted         : integer;
  197.     tshift          : integer;
  198. begin
  199.   CASE text[TextPos] of
  200.     'A'..'Z'         : charnr:=ord(text[TextPos])-64;
  201.     'a'..'z'         : charnr:=ord(text[TextPos])-96;
  202.     ' '              : charnr:=27;
  203.     '?'              : charnr:=28;
  204.     '-'              : charnr:=29;
  205.     '.'              : charnr:=30;
  206.     ''''             : charnr:=31;
  207.     '('              : charnr:=32;
  208.     ')'              : charnr:=33;
  209.     '!',':'          : charnr:=34;
  210.     ELSE charnr:=27;
  211.   end;
  212.   charnr:=charnr-1;
  213.   shifted:=subX shl 1;
  214.   tshift:=TextX shl 2;
  215.   for i:=0 to 24 do begin
  216.     PutPixX(324+shifted+TextAddr shl 2,220+i,mem[seg(Bigfont):ofs(Bigfont)+(charnr*500)+(25*(Tshift+shifted))+i]+226);
  217.     PutPixX(325+shifted+TextAddr shl 2,220+i,mem[seg(Bigfont):ofs(Bigfont)+(charnr*500)+(25*(tshift+1+shifted))+i]+226);
  218.   end;
  219.   ASM cli END;
  220.   Pan(((TextAddr+1)*4)+subX,220);
  221.   ASM sti END;
  222.   for i:=0 to 24 do begin
  223.     PutPixX(shifted+TextAddr shl 2,220+i,mem[seg(Bigfont):ofs(Bigfont)+(500*charnr)+(25*(tshift+shifted))+i]+226);
  224.     PutPixX(shifted+TextAddr shl 2 + 1,220+i,mem[seg(Bigfont):ofs(Bigfont)+(500*charnr)+(25*(tshift+1+shifted))+i]+226);
  225.   end;
  226.   if subX=1 then begin
  227.     inc(TextX);
  228.     if TextX=5 then begin
  229.       TextX:=0;
  230.       inc(TextPos);
  231.     end;
  232.     inc(TextAddr);
  233.     if TextAddr=80 then begin
  234.       TextAddr:=-1;
  235.     end;
  236.   end;
  237.   inc(subX);
  238.   if subX=2 then subX:=0;
  239. end;
  240.  
  241. label mainloop;
  242. begin
  243.   InitMode(V320X240X,640);
  244.   SetSplit(50);
  245.   Pan(0,220);
  246.   subX:=0;
  247.  
  248.   for i:=0 to 255 do begin
  249.     setcolor(i,0,0,0);
  250.     pal[i,1]:=0;
  251.     pal[i,2]:=0;
  252.     pal[i,3]:=0;
  253.   end;
  254.   pal[227,1]:=0;
  255.   pal[227,2]:=0;
  256.   pal[227,3]:=55;
  257.   setcolor(227,0,0,55);
  258.  
  259.   makecheck;
  260.  
  261.   PrepareHSC;
  262.   LoadHSCfile('CHECKER.HSC');
  263.   StartPlaying;
  264.  
  265. Mainloop:
  266.  
  267.   { first loop, normal scroller... }
  268.  
  269.   count:=0;
  270.   fillchar(text,sizeof(text),' ');
  271.   { Not the best way to store the text but it works... }
  272.   text:='Yo SHARP here.. Just a little scroller I made. Lets see what we can do to fill up the emptyness...';
  273.   Textpos:=1;
  274.   TextX:=0;
  275.   TextAddr:=0;
  276.   repeat
  277.     cycletext;
  278.  
  279.     if keypressed then einde;
  280.     inc(count);
  281.   until count=1150;
  282.  
  283.   { second loop, added checkerboard... }
  284.  
  285.   count:=0;
  286.   cols:=check1;
  287.   fillchar(text,sizeof(text),' ');
  288.   text:='Hmmm.. A simple checkerboard... Maybe it can do a little more?!?...';
  289.   Textpos:=1;
  290.   TextX:=0;
  291.   TextAddr:=0;
  292.   repeat
  293.     cycletext;
  294.     allpal;
  295.  
  296.     for i:=1 to 15 do begin
  297.       for j:=0 to 14 do begin
  298.         pal[i+j*15,1]:=cols[(j) * 45+ (i-1) * 3 + 1];
  299.         pal[i+j*15,2]:=cols[(j) * 45+ (i-1) * 3 + 2];
  300.         pal[i+j*15,3]:=cols[(j) * 45+ (i-1) * 3 + 3];
  301.       end;
  302.     end;
  303.     cyclecols(0,2);
  304.  
  305.     if keypressed then einde;
  306.     inc(count);
  307.   until count=830;
  308.  
  309.   { third loop, bit more movement in checker }
  310.   count:=0;
  311.   placecnt:=0;
  312.   fillchar(text,sizeof(text),' ');
  313.   text:='Ahhh.. That''s better... But why such a stuped checkerd pattern?!?...';
  314.   Textpos:=1;
  315.   TextX:=0;
  316.   TextAddr:=0;
  317.   repeat
  318.     cycletext;
  319.     allpal;
  320.     {for i:=1 to 225 do setcolor(i,pal[i,1],pal[i,2],pal[i,3]);}
  321.  
  322.     for i:=1 to 15 do begin
  323.       for j:=0 to 14 do begin
  324.         pal[i+j*15,1]:=cols[(j) * 45+ (i-1) * 3 + 1];
  325.         pal[i+j*15,2]:=cols[(j) * 45+ (i-1) * 3 + 2];
  326.         pal[i+j*15,3]:=cols[(j) * 45+ (i-1) * 3 + 3];
  327.       end;
  328.     end;
  329.     case placecnt of
  330.          0..50     : cyclecols(2,0);
  331.          51..100   : cyclecols(0,-2);
  332.          101..150  : cyclecols(-2,0);
  333.          151..200  : cyclecols(0,2);
  334.          else cyclecols(0,0);
  335.     end;
  336.     inc(placecnt);
  337.     if placecnt=201 then placecnt:=0;
  338.  
  339.     if keypressed then einde;
  340.     inc(count);
  341.   until count=850;
  342.  
  343.   { fourth loop, Different pattern.. }
  344.   count:=0;
  345.   cols:=check2;
  346.   placecnt:=0;
  347.   fillchar(text,sizeof(text),' ');
  348.   text:='Hmm.. U....N..... not the most original but...';
  349.   Textpos:=1;
  350.   TextX:=0;
  351.   TextAddr:=0;
  352.   repeat
  353.     cycletext;
  354.     allpal;
  355.     {for i:=1 to 225 do setcolor(i,pal[i,1],pal[i,2],pal[i,3]);}
  356.  
  357.     for i:=1 to 15 do begin
  358.       for j:=0 to 14 do begin
  359.         pal[i+j*15,1]:=cols[(j) * 45+ (i-1) * 3 + 1];
  360.         pal[i+j*15,2]:=cols[(j) * 45+ (i-1) * 3 + 2];
  361.         pal[i+j*15,3]:=cols[(j) * 45+ (i-1) * 3 + 3];
  362.       end;
  363.     end;
  364.     case placecnt of
  365.          0..50     : cyclecols(2,0);
  366.          51..100   : cyclecols(0,-2);
  367.          101..150  : cyclecols(-2,0);
  368.          151..200  : cyclecols(0,2);
  369.          else cyclecols(0,0);
  370.     end;
  371.     inc(placecnt);
  372.     if placecnt=201 then placecnt:=0;
  373.  
  374.     if keypressed then einde;
  375.     inc(count);
  376.   until count=620;
  377.  
  378.   count:=0;
  379.   fillchar(text,sizeof(text),' ');
  380.   text:='Well... O.K. to business. This little thing was programmed by me -SHARP- the GFX was also done by me... The music';
  381.   text:=text+' came with the hsc player that was made by UCi -Hi Myxtronic - Hi RTF - ....';
  382.   Textpos:=1;
  383.   TextX:=0;
  384.   TextAddr:=0;
  385.   repeat
  386.     cycletext;
  387.     allpal;
  388.     {for i:=1 to 225 do setcolor(i,pal[i,1],pal[i,2],pal[i,3]);}
  389.  
  390.     for i:=1 to 15 do begin
  391.       for j:=0 to 14 do begin
  392.         pal[i+j*15,1]:=cols[(j) * 45+ (i-1) * 3 + 1];
  393.         pal[i+j*15,2]:=cols[(j) * 45+ (i-1) * 3 + 2];
  394.         pal[i+j*15,3]:=cols[(j) * 45+ (i-1) * 3 + 3];
  395.       end;
  396.     end;
  397.     case placecnt of
  398.          0..50     : cyclecols(2,0);
  399.          51..100   : cyclecols(0,-2);
  400.          101..150  : cyclecols(-2,0);
  401.          151..200  : cyclecols(0,2);
  402.          else cyclecols(0,0);
  403.     end;
  404.     inc(placecnt);
  405.     if placecnt=201 then placecnt:=0;
  406.  
  407.     if keypressed then einde;
  408.     inc(count);
  409.   until count=2050;
  410.  
  411.   count:=0;
  412.   fillchar(text,sizeof(text),' ');
  413.   text:='So.. we are comming to the end of this small intro now so here are the greetz - DSF - DUST - Future';
  414.   text:=text+' Crew - Renaissance - RiToSoft - SMA-POSSE - The United Crew - TKB - Triton -';
  415.   Textpos:=1;
  416.   TextX:=0;
  417.   TextAddr:=0;
  418.   repeat
  419.     cycletext;
  420.     allpal;
  421.     {for i:=1 to 225 do setcolor(i,pal[i,1],pal[i,2],pal[i,3]);}
  422.  
  423.     for i:=1 to 15 do begin
  424.       for j:=0 to 14 do begin
  425.         pal[i+j*15,1]:=cols[(j) * 45+ (i-1) * 3 + 1];
  426.         pal[i+j*15,2]:=cols[(j) * 45+ (i-1) * 3 + 2];
  427.         pal[i+j*15,3]:=cols[(j) * 45+ (i-1) * 3 + 3];
  428.       end;
  429.     end;
  430.     case placecnt of
  431.          0..50     : cyclecols(2,0);
  432.          51..100   : cyclecols(0,-2);
  433.          101..150  : cyclecols(-2,0);
  434.          151..200  : cyclecols(0,2);
  435.          else cyclecols(0,0);
  436.     end;
  437.     inc(placecnt);
  438.     if placecnt=201 then placecnt:=0;
  439.  
  440.     if keypressed then einde;
  441.     inc(count);
  442.   until count=1940;
  443.  
  444.   count:=0;
  445.   fillchar(text,sizeof(text),' ');
  446.   text:='Well... I didn''t menage to fill up all the space below me. Heck! we need a GFX-artist so contact me!!! See Ya...';
  447.   Textpos:=1;
  448.   TextX:=0;
  449.   TextAddr:=0;
  450.   repeat
  451.     cycletext;
  452.     allpal;
  453.     {for i:=1 to 225 do setcolor(i,pal[i,1],pal[i,2],pal[i,3]);}
  454.  
  455.     for i:=1 to 15 do begin
  456.       for j:=0 to 14 do begin
  457.         pal[i+j*15,1]:=cols[(j) * 45+ (i-1) * 3 + 1];
  458.         pal[i+j*15,2]:=cols[(j) * 45+ (i-1) * 3 + 2];
  459.         pal[i+j*15,3]:=cols[(j) * 45+ (i-1) * 3 + 3];
  460.       end;
  461.     end;
  462.     case placecnt of
  463.          0..50     : cyclecols(2,0);
  464.          51..100   : cyclecols(0,-2);
  465.          101..150  : cyclecols(-2,0);
  466.          151..200  : cyclecols(0,2);
  467.          else cyclecols(0,0);
  468.     end;
  469.     inc(placecnt);
  470.     if placecnt=201 then placecnt:=0;
  471.  
  472.     if keypressed then einde;
  473.     inc(count);
  474.   until count=1290;
  475.  
  476.  
  477.   for i:=0 to 225 do begin
  478.       pal[i,1]:=0;
  479.       pal[i,2]:=0;
  480.       pal[i,3]:=0;
  481.   end;
  482.  
  483.   for i:=1 to 225 do setcolor(i,pal[i,1],pal[i,2],pal[i,3]);
  484.   goto mainloop;
  485.  
  486.   einde; { the point that i'll never be reached:-) }
  487. end.
  488. { Well that was that.... A simple little thingy isn't?? Hardly any
  489.   uptimization but eh who cares, it works!!!! Heck, I made it just
  490.   cause I wanne to see if it would work, so who cares if it's slow????
  491.   Well I don't!!!!
  492.  
  493.   Have Fun, SHARP......}